﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace PersonalAccounting.Business
{
    public class RegMonthTotal
    {

        #region Attributes

        private int _year;
        private int _month;
        private double _totalIn;
        private double _totalOut;

        #endregion

        #region Properties

        public int Year
        {
            get { return _year; }
            set { _year = value; }
        }

        public int Month
        {
            get { return _month; }
            set { _month = value; }
        }

        public double TotalIn
        {
            get { return _totalIn; }
            set { _totalIn = value; }
        }

        public double TotalOut
        {
            get { return _totalOut; }
            set { _totalOut = value; }
        }

        #endregion

        #region Constructor

        public RegMonthTotal()
        {
            _year = 0;
            _month = 0;
            _totalIn = 0;
            _totalOut = 0;
        }

        public RegMonthTotal(int year, int month)
        {
            _year = year;
            _month = month;
            _totalIn = 0;
            _totalOut = 0;
        }

        #endregion

        #region Public Methods

        public void AddIn(double number)
        {
            _totalIn += number;
        }

        public void AddOut(double number)
        {
            _totalOut += number;
        }

        #endregion

    }
}